package com.platform.user.controller;

import com.platform.bean.JsonResult;
import com.platform.bean.Result;
import com.platform.user.service.TestService;
import com.platform.utils.Base64Utils;
import com.platform.utils.UploadFileToRemoteUtils;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;

import javax.annotation.Resource;
import java.util.Map;

@RestController
@RequestMapping("example")
public class ExampleController {

    @Resource
    private TestService testService;

//    @PostMapping("/test")
//    public Result<String> exampleRequest(@RequestBody Map<String, Object> params) {
//        String content = (String) params.get("content");
//        //System.out.println(params.get("content"));
//        testService.insert(content);
//        return Result.ok("ok666");
//    }

    @GetMapping("/index")
    public String index() {
        return "index";
    }

    @PostMapping("/test")
    public void ok() {
        System.out.println("ok");
    }

    @PostMapping("/testImage")
    public void testImage() {

    }
}
